﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace QQTools.Data.Enums.BlockGroup
{
    public enum BlockGroupStatus
    {
        /// <summary>
        /// 待处理
        /// </summary>
        Pending = 1,
        /// <summary>
        /// 成功
        /// </summary>
        Success = 2,
        /// <summary>
        /// 进行中
        /// </summary>
        Bebeing = 3,
        /// <summary>
        /// 失败
        /// </summary>
        Failed = 4
    }

    public static class BlockGroupStatusExtensions
    {
        public static string ToChineseString(this BlockGroupStatus status)
        {
            switch (status)
            {
                case BlockGroupStatus.Pending:
                    return "-";
                case BlockGroupStatus.Success:
                    return "✔️";
                case BlockGroupStatus.Bebeing:
                    return "⏳";
                case BlockGroupStatus.Failed:
                    return "❌";
                default:
                    return "未知";
            }
        }
    }


    public enum BlockGroupResult
    {
        /// <summary>
        /// 完成
        /// </summary>
        Success = 1,
        /// <summary>
        /// 群未找到
        /// </summary>
        GroupNotFound = 2,
        /// <summary>
        /// 群被封或群未添加
        /// </summary>
        GroupBlockedOrNotAdded = 3,
        /// <summary>
        /// 打开窗口失败
        /// </summary>
        OpenWindowFailed = 4,
        /// <summary>
        /// 出现添加失败窗口
        /// </summary>
        AddFailedWindow = 5,
        /// <summary>
        /// 群已满
        /// </summary>
        FullGroup = 6,
        /// <summary>
        /// 无效群号
        /// </summary>
        InvalidGroupNumber = 7,
        /// <summary>
        /// 未知
        /// </summary>
        Unknown = 100,
        /// <summary>
        /// 浏览器打开失败
        /// </summary>
        BrowserOpenFailed = 101,
        /// <summary>
        /// 任务被取消
        /// </summary>
        TaskCancelled = 102,
        /// <summary>
        /// 错误窗口
        /// </summary>
        ErrorWindow = 103,
        /// <summary>
        /// QQ离线
        /// </summary>
        QQOffline = 104,
    }

}
